<?php

namespace App\Models;

use Eloquent as Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class Bonus extends Model
{
    use SoftDeletes;

    public $table = 'bonuses';
    

    protected $dates = ['deleted_at'];


    public $fillable = [
        'shop_id',
        'bonus_category_id',
        'sn',
        'name',
        'user_id',
        'order_id',
        'distribute_id',
        'money',
        'type',
        'min_amount',
        'max_amount',
        'send_start_date',
        'send_end_date',
        'use_start_date',
        'use_end_date',
        'use_date',
        'use_status',
    ];

    /**
     * The attributes that should be casted to native types.
     *
     * @var array
     */
    protected $casts = [
        'name' => 'string',
        'user_id' => 'integer',
        'distribute_id' => 'integer',
        'type' => 'integer',
        'use_status' => 'integer'
    ];

    /**
     * Validation rules
     *
     * @var array
     */
    public static $rules = [
        
    ];

    
}
